/************************************************************************
                        NurbsTesseloator.h - Copyright Claudio Botta

This library is free software; you can redistribute it and/or modify it 
under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or 
(at your option) any later version.
This library is distributed in the hope that it will be useful, but 
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 
License for more details.

You should have received a copy of the GNU Lesser General Public License 
along with this library; if not, write to the 
Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, 
Boston, MA 02110, USA

This file was generated on Sun Apr 27 2008 at 15:29:34
The original location of this file is geomagick/NurbsTesselator.h
**************************************************************************/


#ifndef NURBSTESSELATOR_H
#define NURBSTESSELATOR_H

#include <string>
#include <vector>
#include <deque>
#include "Conversion.h"
#include "BaseTypes/Nurbs.h"
#include "BaseTypes/Triangles.h"
#include "geomagickGlobal.h"
#include <boost/foreach.hpp>

#include <nurbs++/nurbsS.h>
#include <nurbs++/vector.h>
#include <nurbs++/list.h>
#include <nurbs++/barray.h>
#include <nurbs++/point_nd.h>
#include <nurbs++/hpoint_nd.h>
#include <nurbs++/nurbsS_sp.h>
#include <nurbs++/nurbsSub.h>
//#include <matrix/point_nd.h>

using namespace std;
using namespace geomagick;


/**
  *  \class NurbsTesselator
  *  \brief Offers a Conversion from Nurbs to Triangles
  */

class NurbsTesselator : public Conversion
{
public:


virtual void test()
 {
	cout << "NurbsTesselator \n";
}

  virtual Triangles* process(Nurbs* inNurbs);
  virtual BaseType* process(BaseType* in){
	return this->process((Nurbs*) in);
	}

  



   static Conversion* init(){return (new NurbsTesselator);}
   static string getConversionName(){return "NurbsTesselator";}
   static int getEdgeWeight(){return 1;}
   static ConversionId* getTypeId(){ConversionId* newConversionId = new ConversionId; 
					newConversionId->getSourceId = Nurbs::getTypeId;
					newConversionId->getTargetId = Triangles::getTypeId;
					newConversionId->getEdgeWeight = NurbsTesselator::getEdgeWeight;
					newConversionId->getConversionName = NurbsTesselator::getConversionName;
					newConversionId->init = NurbsTesselator::init; 
					return newConversionId;}

private:

};

#endif // NURBSTESSELATOR_H
